// Copyright (C) 2020 Wuguyannian - All Rights Reserved

using UnrealBuildTool;
using System.IO;

public class TapDB : ModuleRules
{
	public TapDB(ReadOnlyTargetRules Target) : base(Target)
	{
		PCHUsage = ModuleRules.PCHUsageMode.UseExplicitOrSharedPCHs;

		var TapDBLibPath = Path.GetFullPath(Path.Combine(ModuleDirectory, "../ThirdParty/"));

		if(Target.Platform == UnrealTargetPlatform.Android)
        {
            PrivateDependencyModuleNames.Add("Launch");
            PrivateIncludePaths.Add(Path.Combine(ModuleDirectory, "Private/Android"));
			PrivateIncludePaths.Add(Path.Combine(TapDBLibPath, "android"));
		}

		PublicIncludePaths.AddRange(
			new string[] {
				// ... add public include paths required here ...
			}
			);
		
		
		PrivateIncludePaths.AddRange(
			new string[] {
				"TapDB/Private",
				// ... add other private include paths required here ...
			}
			);
		
		
		PublicDependencyModuleNames.AddRange(
			new string[]
			{
				"Core",
				// ... add other public dependencies that you statically link with here ...
			}
			);
		
		
		PrivateDependencyModuleNames.AddRange(
			new string[]
			{
				"CoreUObject",
				"Engine",
				// ... add private dependencies that you statically link with here ...	
			}
			);
		
		
		DynamicallyLoadedModuleNames.AddRange(
			new string[]
			{
				// ... add any modules that your module loads dynamically here ...
			}
			);
		

		// Additional Frameworks and Libraries for Android
		if (Target.Platform == UnrealTargetPlatform.Android)
		{
			string PluginPath = Utils.MakePathRelativeTo(ModuleDirectory, Target.RelativeEnginePath);
			AdditionalPropertiesForReceipt.Add("AndroidPlugin", Path.Combine(PluginPath, "TapDB_UPL.xml"));
		}
	}
}
